import type { CommonServerOptions } from 'vite'

const testConfig: CommonServerOptions['proxy'] = {
  '/api': {
    target: 'http://127.0.0.1:3005',
  },
  '/imgexpress': {
    target: 'http://192.168.0.111:9820',
  },
  // '/imgexpress': {
  //   target: 'http://127.0.0.1:9820',
  // },
  '/geoserver': {
    // target: 'http://127.0.0.1:9999',
    target: 'http://127.0.0.1:8889',
  },
  '/jiejing': {
      // target: "http://zz.ganzhitianxia.com:8345",
      target: 'http://192.168.0.167:9005',
      rewrite: (path) => path.replace(/\/jiejing/, ''),
  },
  '/juhetuceng': {
    target: 'http://192.168.0.167:3007/',
    rewrite: (path) => path.replace(/\/juhetuceng/, ''),
  },
}

export default {
    testConfig,
}
